package com.ordersystem.demo.serviceImpl;

import com.ordersystem.demo.model.OrderDetail;
import com.ordersystem.demo.model.ProductInfo;
import com.ordersystem.demo.respoistory.OrderDetailRespoistory;
import com.ordersystem.demo.service.OrderDetailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class OrderDetailServiceImpl implements OrderDetailService {

    @Autowired
    private OrderDetailRespoistory respoistory;

    @Override
    public List<OrderDetail> findAll() {
        return respoistory.findAll();
    }

    @Override
    public OrderDetail save(OrderDetail orderDetail) {
        return respoistory.save(orderDetail);
    }
}
